FROM openjdk:8-jdk-alpine

RUN echo -e "https://mirror.tuna.tsinghua.edu.cn/alpine/v3.4/main\n\
https://mirror.tuna.tsinghua.edu.cn/alpine/v3.4/community" > /etc/apk/repositories

RUN apk --update add curl bash ttf-dejavu && \
      rm -rf /var/cache/apk/*

ADD chushouya-web-server.jar chushouya-web-server.jar
ENV JAVA_OPTS=$JAVA_OPTS
CMD java ${JAVA_OPTS} -Djava.security.egd=file:/dev/./urandom -jar chushouya-web-server.jar
EXPOSE 9990
